From: Jonas Dreßler Date: Wed, 4 Dec 2019 20:37:34 +0000 (+0100) Subject: checkBox: Fix expand and align properties X-Git-Tag: archive/raspbian/50.5-1+rpi1~1^2~781^2^2~330 X-Git-Url: https://dgit.raspbian.org/%22http://www.example.com/cgi/%22/%22http:/www.example.com/cgi/%22?a=commitdiff_plain;h=f3eeb94c90b9f3d189df33e634d2f4706919d842;p=gnome-shell.git checkBox: Fix expand and align properties In f2bd39b20c89c1896c124f1dccdd587aa544e45c, the expand property for checkboxes was accidentally set to the grandchild (the StBin), instead of the child (the StBoxLayout) of the StButton. Fix that and let the BoxLayout expand instead of the Bin. https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/885 --- diff --git a/js/ui/checkBox.js b/js/ui/checkBox.js index e122fda41..183d719c8 100644 --- a/js/ui/checkBox.js +++ b/js/ui/checkBox.js @@ -4,7 +4,10 @@ const { Clutter, GObject, Pango, St } = imports.gi; var CheckBox = GObject.registerClass( class CheckBox extends St.Button { _init(label) { - let container = new St.BoxLayout(); + let container = new St.BoxLayout({ + x_expand: true, + y_expand: true, + }); super._init({ style_class: 'check-box', child: container, @@ -13,11 +16,7 @@ class CheckBox extends St.Button { can_focus: true, }); - this._box = new St.Bin({ - x_expand: true, - y_expand: true, - y_align: Clutter.ActorAlign.START, - }); + this._box = new St.Bin({ y_align: Clutter.ActorAlign.START }); container.add_actor(this._box); this._label = new St.Label();